<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>SemOpt: AF Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>


</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">SemOpt
   &#160;<span id="projectnumber">0.2alpha5-SCC</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.6.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('classAF.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">AF Class Reference</div>  </div>
</div><!--header-->
<div class="contents">
<!-- doxytag: class="AF" -->
<p>Class encompassing an Argumentation Framework.  
 <a href="classAF.html#details">More...</a></p>
<div class="dynheader">
Collaboration diagram for AF:</div>
<div class="dyncontent">
<div class="center"><img src="classAF__coll__graph.png" border="0" usemap="#AF_coll__map" alt="Collaboration graph"/></div>
<map name="AF_coll__map" id="AF_coll__map">
<area shape="rect" id="node2" href="classSetArguments.html" title="Class encompassing a set of arguments." alt="" coords="5,5,109,35"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="classAF-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ad40517371141b07b06a072d3365bb6de"></a><!-- doxytag: member="AF::AF" ref="ad40517371141b07b06a072d3365bb6de" args="()" -->
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#ad40517371141b07b06a072d3365bb6de">AF</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Simple constructor. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#a40b85b5c4cb3d96273dd0becacad1a79">readFile</a> (string file)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Method for parsing a ASPARTIX compliant file.  <a href="#a40b85b5c4cb3d96273dd0becacad1a79"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#a48e30f0573d51a9995093644bb19bb33">numArgs</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the number of arguments.  <a href="#a48e30f0573d51a9995093644bb19bb33"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classArgument.html">Argument</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#ab2eccb345f0ebfc6fc2b5cb9f456651b">getArgumentByName</a> (string)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This method returns the pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> whose name is given as parameter.  <a href="#ab2eccb345f0ebfc6fc2b5cb9f456651b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classArgument.html">Argument</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#a370edb6cf152935b65e848d1ae209546">getArgumentByNumber</a> (int position)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This method returns the pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> whose identification number is given as parameter.  <a href="#a370edb6cf152935b65e848d1ae209546"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSetArguments.html">SetArguments</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#ac415a440c526e9a06a938544503fe741">get_arguments</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a pointer to the set of arguments.  <a href="#ac415a440c526e9a06a938544503fe741"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSetArguments.html">SetArguments</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#aec0b31f7ddc1405309ebc12644c5c3b5">get_arguments_copy</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a pointer to the set of arguments.  <a href="#aec0b31f7ddc1405309ebc12644c5c3b5"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSetArgumentsIterator.html">SetArgumentsIterator</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#ab5db00d34fb90c9dd41272fd8953a5b4">begin</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Begin of the iterator for the set of arguments.  <a href="#ab5db00d34fb90c9dd41272fd8953a5b4"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSetArgumentsIterator.html">SetArgumentsIterator</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classAF.html#afc7210c999f6af6172e06b984b13ad1a">end</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">End of the iterator for the set of arguments.  <a href="#afc7210c999f6af6172e06b984b13ad1a"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Class encompassing an Argumentation Framework. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>Mauro Vallati &lt;<a href="mailto:m.vallati@hud.ac.uk">m.vallati@hud.ac.uk</a>&gt; </dd></dl>
<dl class="copyright"><dt><b>Copyright:</b></dt><dd>GNU Public License v2 </dd></dl>

<p>Definition at line <a class="el" href="AF_8h_source.html#l00020">20</a> of file <a class="el" href="AF_8h_source.html">AF.h</a>.</p>
</div><hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="ab5db00d34fb90c9dd41272fd8953a5b4"></a><!-- doxytag: member="AF::begin" ref="ab5db00d34fb90c9dd41272fd8953a5b4" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSetArgumentsIterator.html">SetArgumentsIterator</a> <a class="el" href="classAF.html#ab5db00d34fb90c9dd41272fd8953a5b4">AF::begin</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Begin of the iterator for the set of arguments. </p>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname"><a class="el" href="classSetArgumentsIterator.html" title="Class defining a const iterator for the elements of a set of arguments.">SetArgumentsIterator</a></td><td>An iterator pointing at the first of the elements of the set of arguments </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00124">124</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00103">SetArguments::begin()</a>.</p>

</div>
</div>
<a class="anchor" id="afc7210c999f6af6172e06b984b13ad1a"></a><!-- doxytag: member="AF::end" ref="afc7210c999f6af6172e06b984b13ad1a" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSetArgumentsIterator.html">SetArgumentsIterator</a> <a class="el" href="classAF.html#afc7210c999f6af6172e06b984b13ad1a">AF::end</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>End of the iterator for the set of arguments. </p>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname"><a class="el" href="classSetArgumentsIterator.html" title="Class defining a const iterator for the elements of a set of arguments.">SetArgumentsIterator</a></td><td>An iterator pointing at the last of the elements of the set of arguments </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00133">133</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00112">SetArguments::end()</a>.</p>

</div>
</div>
<a class="anchor" id="ac415a440c526e9a06a938544503fe741"></a><!-- doxytag: member="AF::get_arguments" ref="ac415a440c526e9a06a938544503fe741" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSetArguments.html">SetArguments</a> * <a class="el" href="classAF.html#ac415a440c526e9a06a938544503fe741">AF::get_arguments</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns a pointer to the set of arguments. </p>
<p>The function return the very structure used by the <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a> class as a constant: this mean that changes to that SetArgument <b>may</b> change the <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a> instance itself provoking unexpected behaviour. Use this function <b>carefully</b>. If you want a <a class="el" href="classSetArguments.html" title="Class encompassing a set of arguments.">SetArguments</a> that can be changed safely (aka a simple copy of the set of <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a>, not the real handle) you can use the function <a class="el" href="classAF.html#aec0b31f7ddc1405309ebc12644c5c3b5" title="Return a pointer to the set of arguments.">get_arguments_copy()</a> or use the following code: </p>
<div class="fragment"><pre class="fragment">        <a class="code" href="classSetArguments.html" title="Class encompassing a set of arguments.">SetArguments</a>* clone_instance=<span class="keyword">new</span> <a class="code" href="classSetArguments.html" title="Class encompassing a set of arguments.">SetArguments</a>();
        af_instance-&gt;get_arguments()-&gt;clone(clone_instance);
</pre></div><p>For further information about what "const" reserved word mean at the end of a function, you can read the link <a href="http://duramecho.com/ComputerInformation/WhyHowCppConst.html">http://duramecho.com/ComputerInformation/WhyHowCppConst.html</a></p>
<dl class="return"><dt><b>Returns:</b></dt><dd>SetArguments* the very set used by the <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a> instance itself, output as a constant </dd></dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00171">171</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>Referenced by <a class="el" href="AF_8cpp_source.html#l00147">get_arguments_copy()</a>.</p>

</div>
</div>
<a class="anchor" id="aec0b31f7ddc1405309ebc12644c5c3b5"></a><!-- doxytag: member="AF::get_arguments_copy" ref="aec0b31f7ddc1405309ebc12644c5c3b5" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSetArguments.html">SetArguments</a> * <a class="el" href="classAF.html#aec0b31f7ddc1405309ebc12644c5c3b5">AF::get_arguments_copy</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Return a pointer to the set of arguments. </p>
<p>this funtion return a copy editable of the <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a> set of <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a>.</p>
<dl class="post"><dt><b>Postcondition:</b></dt><dd><ul>
<li>a new instance of <a class="el" href="classSetArguments.html" title="Class encompassing a set of arguments.">SetArguments</a> is created in the heap and must be free manually</li>
</ul>
</dd></dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>a changable version of the graph in <a class="el" href="classAF.html" title="Class encompassing an Argumentation Framework.">AF</a> class. </dd></dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00147">147</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00362">SetArguments::clone()</a>, and <a class="el" href="AF_8cpp_source.html#l00171">get_arguments()</a>.</p>

</div>
</div>
<a class="anchor" id="ab2eccb345f0ebfc6fc2b5cb9f456651b"></a><!-- doxytag: member="AF::getArgumentByName" ref="ab2eccb345f0ebfc6fc2b5cb9f456651b" args="(string)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classArgument.html">Argument</a> * <a class="el" href="classAF.html#ab2eccb345f0ebfc6fc2b5cb9f456651b">AF::getArgumentByName</a> </td>
          <td>(</td>
          <td class="paramtype">string&#160;</td>
          <td class="paramname"><em>name</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This method returns the pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> whose name is given as parameter. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">name</td><td>The name of the argument </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">Argument*</td><td>The pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> object, or NULL if not found </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00095">95</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00075">SetArguments::getArgumentByName()</a>.</p>

<p>Referenced by <a class="el" href="AF_8cpp_source.html#l00036">readFile()</a>, and <a class="el" href="SetArguments_8cpp_source.html#l00031">SetArguments::SetArguments()</a>.</p>

</div>
</div>
<a class="anchor" id="a370edb6cf152935b65e848d1ae209546"></a><!-- doxytag: member="AF::getArgumentByNumber" ref="a370edb6cf152935b65e848d1ae209546" args="(int position)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classArgument.html">Argument</a> * <a class="el" href="classAF.html#a370edb6cf152935b65e848d1ae209546">AF::getArgumentByNumber</a> </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>num</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This method returns the pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> whose identification number is given as parameter. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">num</td><td>The name of the argument </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">Argument*</td><td>The pointer to the <a class="el" href="classArgument.html" title="Class representing an Argument.">Argument</a> object, or NULL if not found </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00115">115</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00085">SetArguments::getArgumentByNumber()</a>.</p>

</div>
</div>
<a class="anchor" id="a48e30f0573d51a9995093644bb19bb33"></a><!-- doxytag: member="AF::numArgs" ref="a48e30f0573d51a9995093644bb19bb33" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="classAF.html#a48e30f0573d51a9995093644bb19bb33">AF::numArgs</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the number of arguments. </p>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">int</td><td></td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00104">104</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00066">SetArguments::cardinality()</a>.</p>

<p>Referenced by <a class="el" href="Argument_8cpp_source.html#l00074">Argument::OutVar()</a>, <a class="el" href="AF_8cpp_source.html#l00036">readFile()</a>, and <a class="el" href="Argument_8cpp_source.html#l00084">Argument::UndecVar()</a>.</p>

</div>
</div>
<a class="anchor" id="a40b85b5c4cb3d96273dd0becacad1a79"></a><!-- doxytag: member="AF::readFile" ref="a40b85b5c4cb3d96273dd0becacad1a79" args="(string file)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classAF.html#a40b85b5c4cb3d96273dd0becacad1a79">AF::readFile</a> </td>
          <td>(</td>
          <td class="paramtype">string&#160;</td>
          <td class="paramname"><em>file</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Method for parsing a ASPARTIX compliant file. </p>
<p>It uses part of the code from Samer Nofal's, University of Liverpool </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">file</td><td>A string representing the (relative/absolute) path to the ASPARTIX compliant file </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">bool</td><td>It returns `True` if it can correctly parse the file, `False` otherwise </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="AF_8cpp_source.html#l00036">36</a> of file <a class="el" href="AF_8cpp_source.html">AF.cpp</a>.</p>

<p>References <a class="el" href="SetArguments_8cpp_source.html#l00056">SetArguments::add_Argument()</a>, <a class="el" href="Argument_8cpp_source.html#l00152">Argument::add_attacks()</a>, <a class="el" href="AF_8cpp_source.html#l00095">getArgumentByName()</a>, and <a class="el" href="AF_8cpp_source.html#l00104">numArgs()</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>src/<a class="el" href="AF_8h_source.html">AF.h</a></li>
<li>src/<a class="el" href="AF_8cpp_source.html">AF.cpp</a></li>
</ul>
</div><!-- contents -->
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="classAF.html">AF</a>      </li>

    <li class="footer">Generated on Fri Jan 17 2014 11:47:52 for SemOpt by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.6.1 </li>
   </ul>
 </div>


</body>
</html>
